package com.dbz.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.dbz.entity.RolesMopdule;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface RolesModulesDao extends BaseMapper<RolesMopdule> {
    /**
     * 添加中间角色模块中间表信息
     * @param rid
     * @param mids
     * @return
     */
    public int insertRoleAndModule(String rid,String mids);

    /**
     * 根据id删除
     * @param rid mids
     * @return
     */
    public int deleteRoleAndModules(@Param("rid") String rid, @Param("mids") String mids);

    /**
     * 查询角色是否拥有模块
     * @param rid
     * @return
     */
    public List<RolesMopdule> selectRoMoByRid(String rid);
}
